package com.easyjava;

import com.easyjava.bean.TableInfo;
import com.easyjava.builder.BuildBase;
import com.easyjava.builder.BuildController;
import com.easyjava.builder.BuildMapper;
import com.easyjava.builder.BuildMapperXml;
import com.easyjava.builder.BuildPo;
import com.easyjava.builder.BuildQuery;
import com.easyjava.builder.BuildService;
import com.easyjava.builder.BuildServiceImpl;
import com.easyjava.builder.BuildTable;
import java.util.List;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 * @program: workspace-easyjava
 * @description:
 * @author: cw
 * @create: 2024-05-08 10:52
 **/
public class RunAplication {

    private static final Logger log = LoggerFactory.getLogger(RunAplication.class);

    public static void main(String[] args) {
        List<TableInfo> tables = BuildTable.getTables();
        // 生成基础类
        BuildBase.execute();
        for (TableInfo table : tables) {
            BuildPo.execute(table);
            BuildQuery.execute(table);
            BuildMapper.execute(table);
            BuildMapperXml.execute(table);
            BuildService.execute(table);
            BuildServiceImpl.execute(table);
            BuildController.execute(table);
        }
        log.info("生成完毕");
    }
}
